#!/usr/bin/perl
# Simple Browser Identification
# Created by Matt Wright
# Created on: 10/15/95          Last Modified on: 10/15/95
# Version 1.0
# Readme at bottom

################################################################
# Define Variables

$netscape_url = "http://your.host.xxx/netscape.html";
$other_url = "http://your.host.xxx/other.html";

# Done
################################################################

$browser = "$ENV{'HTTP_USER_AGENT'}";

if ($browser =~ /Mozilla/) {   # If they are using Netscape browser
   print "Location: $netscape_url\n\n";
} 
else {                         # For any other browser
   print "Location: $other_url\n\n";
}

# README - (anywhere below or at this line can be chopped out of this file)
# This is a simple script which allows you to send users with a Netscape 
# browser to a certain page, while others go to another page.
# $netscape_url should be the url you want netscape users to go to.
# $other_url should be the url you want other browsers to parse.

# This script could also be modified to state the browser name to those viewing
# your page.  Simply chop out everything after the $browser = ""; line and 
# replace it with:

#  print "Content-type: text/html\n\n";
#  print "You are using $browser to view these pages!\n";

# Of course this example would most likely be used with server side includes.
